package com.xinghou.platform.server.api.service.impl;

import java.io.IOException;
import java.util.List;

import org.springframework.stereotype.Service;

import com.xinghou.platform.lucene.main.UserLuceneService;
import com.xinghou.platform.model.main.User;
import com.xinghou.platform.model.main.UserInfo;
import com.xinghou.platform.server.api.service.UserLuceneApiService;

import javax.annotation.Resource;

@Service("userLuceneApiService")
public class UserLuceneApiServiceImpl extends BaseDAOProtery<UserLuceneService> implements UserLuceneApiService {

	@Resource
	private UserLuceneService userLuceneService ;
	
	public List<User> getSearchUserInfos(String key, int fromno, int pagesize, String userType,String provinceCode) throws IOException {
		return userLuceneService.getSearchUserInfos(key, fromno, pagesize, userType, provinceCode);
	}

	public int saveUserInfo(User user) {
		return userLuceneService.saveUserInfo(user);
	}

	public int updateUserInfo(User user) {
		return userLuceneService.updateUserInfo(user);
	}

	public List<User> getSearchUserInfos(String key, int fromno,int pagesize, String userType, String citycode,Double distance, double lng,double lat) throws IOException {
		return userLuceneService.getSearchUserInfos(key, fromno, pagesize, userType, citycode,distance, lng, lat);
	}

}
